package com.erbao.dp.itrator;

/**
 * @author CaoBaoYin
 * @since 2021/9/21 11:10
 */
public class Main {

    public static void main(String[] args) {
        Collection_<String> c = new ArrayList_<>();

        for (int i = 0; i < 15; i++) {
            c.add("item_"+i);
        }

        System.out.println("容器大小："+c.size());

        Iterator_<String> it = c.iterator();
        while (it.hasNext()){
            String s = it.next();
            System.out.println(s);
        }
    }

}
